<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>

<head>
	<meta charset="utf-8" />
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="icon" href="img/favicon.png" />
	<link rel="stylesheet" href="css/bootstrap.min.css" />
	<link rel="stylesheet" href="css/style.css">		
	<link rel="stylesheet" href="css/font-awesome.min.css" />
	<link rel="stylesheet" href="css/responsive.css">
	<link rel="stylesheet" type="text/css" href="css/shop.css"/>
	<title>苋春-购物车</title>
</head>
<style>

    .num{
        display:inline-block;
        width:3em;
    }
    input{
        height:2em;
    }
    .talast{
        text-align: left;
    }
</style>
<body>
	<!--页头-->
		<header class="buddy-header">
			<div class="top-bar">
				<div class="container">
					<div class="row">
						<div class="col-md-6 col-sm-6 col-xs-12">
							<ul class="n-menu">
								<li>
									<a href="account?act=0"><i class="fa fa-user"></i>我的账户</a>
								</li>
							</ul>
						</div>
					</div>
				</div>
			</div>

			<div class="logo-menu-sec">
				<div class="container">
					<div class="row">
						<div class="logo-sec">
							<div class="col-md-3 col-lg-3 col-sm-4 col-xs-12">
								<div class="logo">
									<a href="index" title=""><img src="img/logo.png" alt="" /></a>
								</div>
							</div>
							<div class="col-md-6 col-lg-5 col-sm-4 hidden-xs">
								<ul class="quick-prom">
									<li><i class="fa fa-phone"></i> <span>咨询电话 : <a href="#">100200300</a></span></li>
									<li class="hidden-sm"><i class="fa fa-envelope-o"></i><span>邮箱：<a href="#">mail@example.com</a></span></li>
								</ul>
							</div>
						<div class="col-md-3 col-lg-4 col-sm-4 col-xs-12">
							<div class="product-filter-form">
								<form method="post" action="shoplist?s=1" id="find">
									<input type="text" name="search" placeholder="搜索商品" />
									<button type="submit" id="searchbtn"><i class="fa fa-search"></i></button>
								</form>
							</div>
						</div>
						</div>
					</div>
				</div>
			</div>

			<div class="main-menu-area">
				<div class="container">
					<div class="row">
						<div class="col-md-10 col-sm-9 col-xs-12">
							<nav class="main-menu">
								<ul>
									<li class="active">
										<a href="index"> <i class="fa fa-home"></i>主页</a>
									</li>
									<li>
										<a href="shoplist?s=0">热卖鲜花</a>
										<div class="mega-menu common-mega ">
											<div class="col-md-3 col-sm-3">
												<div class="mega-menu-lists">
													<a title="" href="shoplist?lid=1&s=2"><span>生日祝福</span></a>
													<a title="" href="shoplist?lid=2&s=2">鲜花礼盒</a>
													<a title="" href="shoplist?lid=3&s=2">单支花朵</a>
													<a title="" href="shoplist?lid=4&s=2">一束鲜花</a>
													<a title="" href="shoplist?lid=5&s=2">创意花束</a>
												</div>
											</div>
											<div class="col-md-3 col-sm-3">
												<div class="mega-menu-lists">
													<a title="" href="shoplist?lid=6&s=2"><span>表白/纪念</span></a>
													<a title="" href="shoplist?lid=7&s=2">周年纪念</a>
													<a title="" href="shoplist?lid=8&s=2">初恋表白</a>
													<a title="" href="shoplist?lid=9&s=2">暗恋闻香</a>
													<a title="" href="shoplist?lid=10&s=2">友谊长存</a>
												</div>
											</div>
											<div class="col-md-3 col-sm-3">
												<div class="mega-menu-lists">
													<a title="" href="shoplist?lid=11&s=2"><span>节日祝福</span></a>
													<a title="" href="shoplist?lid=12&s=2">情人节</a>
													<a title="" href="shoplist?lid=13&s=2">圣诞节</a>
													<a title="" href="shoplist?lid=14&s=2">教师节</a>
													<a title="" href="shoplist?lid=15&s=2">儿童节</a>
												</div>
											</div>
											<div class="col-md-3 col-sm-3">
												<div class="mega-menu-lists">
													<a title="" href="shoplist?lid=16&s=2"><span>毕业典礼</span></a>
													<a title="" href="shoplist?lid=17&s=2">送师姐</a>
													<a title="" href="shoplist?lid=18&s=2">送师兄</a>
													<a title="" href="shoplist?lid=19&s=2">送老师</a>
													<a title="" href="shoplist?lid=20&s=2">送班级</a>
												</div>
											</div>
											<div class="mega-img">
												<a href="javascript:;"><img src="img/ad3.jpg" alt=""></a>
											</div>
										</div>

									</li>
									<li>
										<a href="shoplist?lid=1&s=2">鲜花爆款</a>
										<ul class="ddown">
											<li class="mega-menu-lists">
												<a href="shoplist?lid=1&s=2">玫瑰</a>
											</li>
											<li class="mega-menu-lists">
												<a href="shoplist?lid=2&s=2">向日葵</a>
											</li>
											<li class="mega-menu-lists">
												<a href="shoplist?lid=3&s=2">绣球</a>
											</li>
											<li class="mega-menu-lists">
												<a href="shoplist?lid=4&s=2">洋桔梗</a>
											</li>
										</ul>
									</li>
									<li>
										<a href="video">视频教程</a>
										<ul class="ddown">
											<li class="mega-menu-lists">
												<a target="_blank" href="video">醒花教程</a>
											</li>
											<li class="mega-menu-lists">
												<a target="_blank" href="video">插花艺术</a>
											</li>
											<li class="mega-menu-lists">
												<a target="_blank" href="video">包扎教程</a>
											</li>
											<li class="mega-menu-lists">
												<a target="_blank" href="video">鲜花保养</a>
											</li>
										</ul>
									</li>

								</ul>

							</nav>

							<div class="mobile-menu-area">
								<nav id="mobile-menu">
									<ul>
										<li>
											<a href="index">主页</a>
										</li>
										<li>
											<a href="shoplist?lid=1&s=2">热卖鲜花</a>
											<ul>
												<li>
													<a href="shoplist?lid=1&s=2">生日祝福</a>
												</li>
												<li>
													<a href="shoplist?lid=1&s=2">表白/纪念</a>
												</li>
												<li>
													<a href="shoplist?lid=1&s=2">节日祝福</a>
												</li>
												<li>
													<a href="shoplist?lid=1&s=2">毕业典礼</a>
												</li>
											</ul>
										</li>
										<li>
											<a href="shoplist?lid=1&s=2">鲜花爆款</a>
											<ul>
												<li class="#">
													<a href="shoplist?lid=1&s=2">玫瑰</a>
												</li>
												<li class="#">
													<a href="shoplist?lid=1&s=2">向日葵</a>
												</li>
												<li class="#">
													<a href="shoplist?lid=1&s=2">绣球</a>
												</li>
												<li class="#">
													<a href="shoplist?lid=1&s=2">洋桔梗</a>
												</li>
											</ul>
										</li>
										<li>
											<a href="video">视频教程</a>
										</li>
										<li>
											<a href="javascript:;">联系我们</a>
										</li>
										<li>
											<a href="javascript:;">博客日志</a>
										</li>
									</ul>
								</nav>
							</div>

						</div>

						<div class="col-md-2 col-sm-3 hidden-xs">
							<div class="cart-wishlist">
								<ul>
									<li>
										<a href="cart?act=0">
											<div class="wish-list-inner">
												<div class="cart-icon">
													<i class="fa fa-shopping-cart" id="end"> </i>
												</div>
											</div>
										</a>
										<div class="ab">
											<div class="btn-mini-cart inline-lists">
												<a href="cart?act=0" class="button btn-viewcart">浏览购物车</a>
												<a href="checkout" class="button btn-checkout" title="Checkout">结账</a>
											</div>
										</div>
									</li>
								</ul>
							</div>
						</div>
					</div>
				</div>
			</div>
		</header>
	<!-- 主内容 -->

	<div class="cart-area pt55 pb55 ">
		<div class="container">
			<div class="row">
				<div class="col-md-12 col-sm-12 col-xs-12">
					<div class="section-title text-center pt40">
						<h2>购物车</h2>
					</div>
					
						<div class="table"  id="abc">
							<table class="shop_table cart table">
								<thead>
									<tr>
                                        <th class="product-choice">序号</th>
                                        <th class="product-thumbnail">商品图片</th>
										<th class="product-name">商品详情</th>
										<th class="product-quantity">商品数量</th>                                        
										<th class="product-price">商品价格</th>                                        
                                        <th class="product-subtotal">商品总价</th>
										<th class="product-remove">删除</th>                           
                                    </tr>
                                </thead>
                                <tbody>
                                <c:forEach items="${clist }" var="clist" varStatus="s">
                                	 <tr class="trclass">
                                        <td class="product-choice xuhao">${s.count }</td>
                                        <td class="item-img">
                                            
                                            <a href="details?gid=${glist.get(s.index).getGid()}&uid=${uid}"><img src="img/shop/${glist.get(s.index).getPhoto() }" alt=""> </a>
                                        </td>
                                        <td class="product-name " >${glist.get(s.index).getGname() }</td>
                                        	<td class="product-quantity">
                                        		<span class="jiajie">
                                        			${clist.getShopnum() }
                    							</span>
                    						</td>
                                        <td class="product-price"><span>单价：</span><span class="unit">${glist.get(s.index).getPrice() }</span></td>
                                        <td class="product-subtotal"><span>小计：</span><span class="subtal">${glist.get(s.index).getPrice() * clist.getShopnum()  }</span></td>
<%--                                         <td class="product-remove"><a href="cart?cid=${clist.getCartid()}&act=2">删除</a></td> --%>
										<td class="product-remove"><input type="button" id="Button1" onClick="delCart('${clist.getCartid()}','2',this);" value="删除"></td>

                                    </tr>
                                
                                </c:forEach>
                                    <tr><td  colspan="7" class="talast"> 其中最贵的商品单价是 <span class="pricest">${max_price } 元</span></td></tr>
                                </tbody>
                            </table>
						</div>
					
					<div class="total-cart-wrap pt30">
						<div class="section-title text-center pt40">
							<h3>购物车总计</h3>
						</div>
						<form method="post" action="cart?act=4" id="goods${s.count }">
							<div class="table-responsive">
								<table class="cart-total-area table">
									<tbody>
										<tr class="cart_item">
											<td class="ctg-type">商品总数</td>
											<td class="cgt-des"> <span class="goods_num">${total_num }</span> 件</td>
										</tr>
										<tr class="cart_item">
											<td class="ctg-type"> 运送方式</td>
											<td class="cgt-des">免运费 </td>
										</tr>
										<tr class="cart_item">
											<td class="ctg-type">总金额</td>
											<td class="cgt-des total"> ¥ <span class="pricetal">${total_price }</span></td>
										</tr>
									</tbody>
								</table>
								<div class="input-box tci-box text-center">
									<a href="checkout">
										<input type="button" class="in-btn place-order" value="提交订单">
									</a>
									
								</div>
							</div>
						</form>
					</div>
				</div>
			</div>
		</div>
	</div>
	
	<!--页脚-->
	<div class="section-info pt55 pb55">
		<div class="parallax-bg">
			<div class="section-content">
				<div class="container">
					<div class="row">
						<div class="col-md-4 col-sm-6 col-xs-12">
							<a class="info-block" href="#"><i class="fa fa-truck"></i>
								<h3>免费送货</h3>
								<p>学校的每一个角落</p>
							</a>
						</div>
						<div class="col-md-4 col-sm-6 col-xs-12">
							<a class="info-block" href="#"><i class="fa fa-headphones"></i>
								<h3>支持定制</h3>
								<p>全天候24小时支持</p>
							</a>
						</div>
						<div class="col-md-4 col-sm-6 col-xs-12">
							<a class="info-block" href="#"><i class="fa fa-diamond"></i>
								<h3>高品质</h3>
								<p>拥有最好的品质和品牌</p>
							</a>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>
	<footer>
		<div class="footer-widgets-area pt55">
			<section class="block">
				<div class="container">
					<div class="row">
						<div class="col-md-12">
							<div class="content-box no-margin go-simple">
								<div class="row">
									<div class="col-md-3 col-sm-4 col-xs-12">
										<div class="widget about-widget">
											<div class="logo">
												<a href="index"><img alt="" src="img/logo.png"></a>
											</div>
											<p>你好，世界！</p>
											<ul>
												<li>
													<i class="fa fa-map-marker"></i> 广州南方学院
												</li>
												<li>
													<i class="fa fa-phone"></i> 110-0487 &nbsp;&nbsp;&nbsp; 119-04887
												</li>
											</ul>
										</div>
									</div>
									<div class="col-md-3 col-sm-4 col-xs-12">
										<div class="widget how-to-buy">
											<h3 class="heading2">服务</h3>
											<ul>
												<li>
													<a href="#" title="">联系我们</a>
												</li>
												<li>
													<a href="#" title="">礼品</a>
												</li>
												<li>
													<a href="#" title="">VIP</a>
												</li>
											</ul>
										</div>
									</div>
									<div class="col-md-3 hidden-sm col-xs-12">
										<div class="widget customer-services">
											<h3 class="heading2">信息</h3>
											<ul>
												<li>
													<a href="#" title="">关于我们的店铺</a>
												</li>
												<li>
													<a href="#" title="">安全购物</a>
												</li>
												<li>
													<a href="#" title="">隐私政策</a>
												</li>
											</ul>
										</div>
									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
			</section>
		</div>
	</footer>	
	
</body>

		
<script src="js/jquery-1.12.3.min.js" ></script>	
<script src="js/jquery-3.1.1.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/owl.carousel.min.js"></script>
<script src="js/jquery.meanmenu.js"></script>
<script src="js/jquery.mousewheel.min.js" type="text/javascript" charset="utf-8"></script>
<script src="js/wow.min.js"></script>
<script src="js/jquery.nivo.slider.pack.js"></script>
<script src="js/plugins.js"></script>
<script src="js/main.js"></script>
<script src="js/a.js"></script>

<!-- <script src="js/cart.js"></script> -->


<!-- <script>
	function del(obj) {
		obj.parentNode.parentNode.remove();
	}
</script> -->
</html>